﻿@model  IEnumerable<Web.Domain.Entities.Display>
@{
    ViewBag.Title = "dAciton";
    Layout = "~/Views/Shared/_AdminLayout.cshtml";
}
@{
    var grid = new WebGrid(source: Model, defaultSort: "id", rowsPerPage: 10, canPage: true);
}
<h2>
    dAciton</h2>
<!-- Page Head -->
<ul class="shortcut-buttons-set">
    <li><a class="shortcut-button" href="~/Compo/CreateDis"><span>
        <img src="~/Content/images/icons/pencil_48.png" alt="icon" /><br />
        添加新项 </span></a></li>
</ul>
<!-- End .shortcut-buttons-set -->
<div class="clear">
</div>
<!-- End .clear -->
@Html.Partial("msgbox")
<div class="content-box">
    <!-- Start Content Box -->
    <div class="content-box-header">
        <h3>
            显示方式</h3>
        <div class="clear">
        </div>
    </div>
    <div class="content-box-content">
        <div class="tab-content default-tab" id="tab1">
            @grid.GetHtml(
            tableStyle: "table",
            footerStyle: "pagination",
                columns: grid.Columns(
                grid.Column("id", "序号"),
                grid.Column("Name", "标题"),
                grid.Column("CompoId", "控制器"),
                  grid.Column(null, "编辑", format: @<text>@Html.ActionLink("显示方法", "dAction", new { id = item.id })
            | @Html.ActionLink("编辑", "Editor", new { id = item.id })
            | @Html.ActionLink("删除", "Delete", new { id = item.id })</text>))
                  , mode: WebGridPagerModes.All, firstText: "第一页", previousText: "上一页", nextText:
            "下一页", lastText: "最后一页", numericLinksCount: 5)
        </div>
    </div>
</div>
